Geometric Styles, Inks, and Transforms
Like all QuickDraw GX shapes, geometric shapes reference a style object, an ink object, and a transform object. Figure 1-5 shows a condensed view of how a polygon shape might use these four objects.Instead of listing every property of each of these objects, the first half of Figure 1-5 (the left side) depicts a single important property for each object:
This condensed view of these objects is used frequently throughout this book to highlight information important to a particular example.
- For the shape object, it shows the polygon geometry.
- For the style object, it shows the pen width.
- For the ink object, it shows the color.
- For the transform object, it shows the transformation mapping.
The second half of Figure 1-5 (the right side) shows an even more condensed view of the polygon shape. In this view, all of the stylistic, color, and transform variations have been incorporated into the shape itself--basically showing the shape as it is drawn. This extremely condensed view is used occasionally throughout this book, particularly when many shapes must appear in a single figure, as in the chapter "Picture Shapes."
Figure 1-5 Two condensed views of a polygon shape
Because the ink and transform objects are used in the same way by geometric and typographic shapes, these two objects are discussed in Inside Macintosh: QuickDraw GX Objects, rather than in this book.
However, geometric shapes use their style objects in a very different way than typographic shapes do.
The style object has three types of properties:
The geometric style properties are the properties of the style object that specify modifications to geometric shapes. With these properties, you can specify how wide QuickDraw GX should draw a shape's edges, whether the edges should be solid or dashed, whether corners should be round or sharp, what pattern should fill a shape's area, and so on.
- Object-related style properties, which are discussed in the chapter "Style Objects" in Inside Macintosh: QuickDraw GX Objects. These properties apply to the style as an object in memory.
- Typographic style properties, which are discussed in the chapter "Typographic Styles" in Inside Macintosh: QuickDraw GX Typography. These properties apply only to typographic shapes.
- Geometric style properties, which are discussed in the chapter "Geometric Styles" in this book. These properties apply primarily to geometric shapes.
Figure 1-6 shows the geometric properties of the style object. This figure also gives examples of the effects of these properties.
Figure 1-6 The geometric style properties and some examples of their effects
Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help